﻿using System;

namespace tnet.Model
{ 
    public class RssItem
    {
        private String _Title = String.Empty;
        private String _Link = String.Empty;
        private String _Img = String.Empty;
        private Double _ImageWidth;
        private String _Description = String.Empty;
        private String _FreezeDried = String.Empty;

        public String Title
        {
            get { return _Title; }
            set { _Title = value; }
        }
         
        public String Link
        {
            get { return _Link; }
            set { _Link = value; }
        }
         
        public String Img
        {
            get { return _Img; }
            set { _Img = value; }
        }
         
        public Double ImageWidth
        {
            get 
            {
                if (String.IsNullOrEmpty(Img))
                {
                    return 0.0;
                }
                else
                {
                    return 70.0;
                }  
            }
            set { _ImageWidth = value; }
        }
         
        public String Description
        {
            get { return _Description; }
            set { _Description = value; }
        }
         
        public String FreezeDried
        {
            get
            {
                return Title + "^" + Link + "^" + Img + "^" + Description;
            } 
        }
    }
}
